package com.chenyi.leetcode.editor.cn;

import java.util.Arrays;

/**
 * @author chenyi
 * @className Test
 * @date 2022/8/27 16:28
 */
public class Test {
    public static void main(String[] args) {
        int[] arr = {1, 3, 2, 4, 11, 12, 466, 1231, 222};
        int left = 0;
        int right = arr.length - 1;
        while (left < right) {
            int temp = arr[left];
            arr[left] = arr[right];
            arr[right] = temp;
            left++;
            right--;
        }
        System.out.println(Arrays.toString(arr));
    }
}
